/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.mx.im.sinocab.util;

/**
 *
 * @author javilesc
 */
public interface Constant {

    /* SESION */
    final String SQL_USER_VERIFICATION = "SELECT e.idEmploy, e.name, e.lastName, e.address, e.phone, e.email, e.birthday, u.idUser, u.user, u.password, u.expiry, ut.idUserType, ut.definition, ut.description,e.gender FROM employ AS e INNER JOIN (user AS u INNER JOIN userType AS ut ON u.idUserType = ut.idUserType) ON u.idEmploy = e.idEmploy WHERE u.user = ? and u.password = ?;";
    
    
    /* ADMIN MENUS */
    final String SQL_LIST_MENU_OPTIONS = "SELECT o.idOption,o.option, o.description, o.actionRequest, o.status, u.idUser, u.user, ut.idUserType , ut.definition AS ut_definition, ut.description AS ut_description, e.idEmploy, e.name, e.lastName, e.address, e.phone, e.email, e.birthday, e.gender, m.idMenu AS m_idmenu, m.menu AS m_menu, m.description AS m_description, m.status AS m_status, um.idUser AS um_idUser, um.user AS um_user, utm.idUserType As utm_idUserType, utm.definition AS utm_definition, utm.description AS utm_description, em.idEmploy AS em_idEmploy, em.name AS em_name, em.lastName AS em_lastName, em.address AS em_address, em.phone AS em_phone, em.email AS em_email, em.birthday AS em_birthday, em.gender AS em_gender FROM `menu` AS m LEFT JOIN `option` AS o ON o.idmenu=m.idmenu LEFT JOIN `user` AS u ON o.idUser = u.idUser LEFT JOIN `userType` AS ut ON ut.idUserType = u.idUserType LEFT JOIN `employ` AS e ON e.idEmploy = u.idEmploy LEft JOIN `user` AS um ON m.idUser = um.idUser LEFT JOIN `userType` AS utm ON utm.idUserType = um.idUserType LEFT JOIN `employ` AS em ON em.idEmploy = um.idEmploy;";
    final String SQL_INSERT_OPTION = "INSERT INTO `option` (idUser, idMenu, `option`, description, actionRequest, status) values (?,?,?,?,?,?);";
    final String SQL_INSERT_MENU = "INSERT INTO `menu` (idUser,`menu`, description, status) values (?,?,?,?);";
    
    /* ADMIN USERS */
    final String SQL_LIST_ALL_USERS = "SELECT u.idUser, u.user, u.expiry, ut.idUserType, ut.definition, ut.description, e.idEmploy, e.name, e.lastname, e.address, e.phone, e.email, e.birthday, e.gender FROM `user` AS u INNER JOIN `userType` AS ut ON ut.idUserType = u.idUserType INNER JOIN `employ` AS e ON e.idEmploy = u.idEmploy;";

    

    /* INSERT EMPLOY */
    final String SQL_INSERT_EMPLOY = "INSERT INTO `employ` (name, lastName, phone, cellphone, address, gender, birthday, age, email, admissionDate, timeLaboring, dependentEconomic, workedTipe, maritalStatus, studies) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?);";
    
    /* INSERT EMPLOY */
    final String SQL_CONSULT_EMPLOY = "SELECT * FROM employ";
    
    final String SQL_CONSULT_EMPLOY_WHEREID = "SELECT * FROM employ WHERE idEmploy='?';";
    
    

    
  

}

